{extend name="index_layout"/}
{block name="main"}
<form class="layui-form" method="post">

    <div class="layui-form-item">
        <label class="layui-form-label">名称</label>
        <div class="layui-input-block">
            <input id="c-name" lay-verify="required" class=" layui-input" name="row[name]" type="text" value="{$data.name}">
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">分组</label>
        <div class="layui-input-block">
            <input id="c-vip_cate" lay-verify="required" class=" layui-input" name="row[vip_cate]" type="number" value="{$data.vip_cate}">
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">会员类型</label>
        <div class="layui-input-block">
            <select name="row[expire_type]" id="">
                <option value="1" {if $data.expire_type==1}selected{/if}>月</option>
                <option value="2" {if $data.expire_type==2}selected{/if}>季</option>
                <option value="3" {if $data.expire_type==3}selected{/if}>年</option>
                <option value="4" {if $data.expire_type==4}selected{/if}>终身</option>
            </select>
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">数量</label>
        <div class="layui-input-block">
            <input id="c-nums" lay-verify="required" class=" layui-input" name="row[nums]" type="number" value="{$data.nums}">
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">价格</label>
        <div class="layui-input-block">
            <input id="c-price" lay-verify="required" class=" layui-input" step="0.01" name="row[price]" type="number" value="{$data.price}">
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">折扣</label>
        <div class="layui-input-block">
            <input id="c-discount" lay-verify="required" class=" layui-input" step="0.01" name="row[discount]" type="number" value="{$data.discount}">
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">排序</label>
        <div class="layui-input-block">
            <input id="c-sort" lay-verify="required" class=" layui-input" name="row[sort]" type="number" value="{$data.sort}">
        </div>
    </div>
    <div class="layui-form-item">
        <label class="layui-form-label">描述</label>
        <div class="layui-input-block">
            <textarea id="c-desc" class="editor layui-textarea" rows="5" name="row[desc]" cols="50">{$data.desc}</textarea>
        </div>
    </div>
    <div class="layui-form-item layer-footer">
        <div class="layui-input-block">
            <button class="layui-btn" lay-submit="">立即提交</button>
            <button type="reset" class="layui-btn layui-btn-primary">重置</button>
        </div>
    </div>
</form>
{/block}
{block name="script"}
<script type="text/javascript">
layui.use('yznForm', function() {
    var yznForm = layui.yznForm;
    yznForm.bindevent($("form.layui-form"));
});
</script>
{/block}